package com.bachongLightNovel.error;

public enum ErrorCodeEnum {

    UNKNOW_ERROR(501, "未知错误"),
    USER_NOT_EXIST(510, "用户不存在"),
    PASSWORD_ERROR(511, "密码错误"),
    ADMIN_NOT_UPDATE(512, "admin用户不允许操作"),
    ACCOUNT_OTHER_LOGIN(512, "账号在异地登录"),
    LOGIN_TIMEOUT(513, "登录过期"),
    NOVEL_NAME_ILLEGAL(520, "小说名称不能为空"),
    NOVEL_IMAGE_ILLEGAL(521, "小说封面不合法"),
    NOVEL_DESCRIPTION_ILLEGAL(522, "小说简介不合法"),
    NOVEL_DETAIL_TITLE_ILLEGAL(523, "小说章节名不能为空"),
    NOVEL_ID_ILLEGAL(524, "小说id不合法"),
    NOVEL_DETAIL_CONTENT_ILLEGAL(525, "小说章节内容为空"),
    NOVEL_DETAIL_NOT_EXISTS(526, "小说章节不存在"),
    FEIGN_ERROR(530, "调用feign出错！"),
    AUDIT_NOT_PASS_INFO_EMPTY(531, "驳回信息不能为空"),
    COLLECT_IS_EXISTS(501, "该作品已收藏，请重试"),
    COLLECT_IS_NOT_EXISTS(501, "该作品未被收藏，请重试"),
    PHONE_IS_EXISTS(501, "手机号已被注册，请重试"),
    USER_IS_EXISTS(501, "用户已存在");
    private Integer code;
    private String message;

    private ErrorCodeEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
